package com.easybuy.dao;

import com.easybuy.Tools.Page;
import com.easybuy.pojo.Product;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface ProductMapper {
    List<Product> selectProducts(Map map);
    int selectCount(Map map);
    Product selectProductById(@Param("id") int id);
    Product selectProductByName(@Param("name") String name);
    int allCount();
    List<Product> allProducts(Page page);
    int addProduct(Product product);
    int deleProduct(@Param("id") int id);
    int updateProduct(Product product);
}
